// bacth, 10:30 AM 7/11/2008
function newslist_cboIsHot_selectedIndexChange(e)
{
	var newsID = 0;
	var tr = e.parentNode;
	while(tr.nodeName.toLowerCase() != 'tr') tr = tr.parentNode;
	newsID = tr.getElementsByTagName('input')[0].value;
	hdArgs.value = newsID + ',' + e.options[e.selectedIndex].value;
	__doPostBack(btnSetLoaiTin.name,'');
}
function newslist_chkIsFocus_CheckedChanged(e)
{
	var newsID = 0;
	var tr = e.parentNode;
	while(tr.nodeName.toLowerCase() != 'tr') tr = tr.parentNode;
	newsID = tr.getElementsByTagName('input')[0].value;
	hdArgs.value = newsID + ',' + e.checked;
	__doPostBack(btnSetTieuDiem.name,'');
}
function newslist_setstyleforcheckbox()
{
	/*var chk, chks =  document.getElementById(grdListNewsID).getElementsByTagName('input');
	var i = 0, count = chks.length;
	var td;
	for (i=1; i<count; i++)
	{
		chk = chks[i];
		if (chk.type.toLowerCase() == 'checkbox')
		{
			td = chk.parentNode; while (td.nodeName.toLowerCase() != 'td') td = td.parentNode;
			if (chk.checked)
				td.className = 'active'; 
			else
				td.className = '';
			
		}
	}*/
}
function newslist_grid_clickitem(td, newsID)
{
	hdNewsID.value = newsID;
}
function newslist_setstylefordropdownlist()
{
	/*var cbo, cbos =  document.getElementById(grdListNewsID).getElementsByTagName('select');
	var i = 0, index = 0, count = cbos.length;
	var td;
	for (i=0; i<count; i++)
	{
		cbo = cbos[i];
		if (cbo.type.toLowerCase() == 'select-one')
		{
			td = cbo.parentNode; while (td.nodeName.toLowerCase() != 'td') td = td.parentNode;
			index = cbo.selectedIndex;
			if (index == 0)
			{
				td.className = ''; 
				cbo.className = '';	 
			}
			else
			{
				td.className = 'active'; 
				cbo.className = 'active';
			}
		}
	}*/
}
function CloseComment()
{
	document.getElementById('divShowComment').style.display = 'none';
	document.getElementById("bgFilter").style.display = 'none';
}
function ClosePop()
{
	document.getElementById('loginForm').style.display = 'none';
	document.getElementById("bgFilter").style.display = 'none';
}
ie ?  window.attachEvent('onload', newslist_init) : window.addEventListener('load', newslist_init, false);
